package vg_connector.interfaces.actions;

import java.util.UUID;

/**
 * @author Timur Zolotuhin (tzolotuhin@parallels.com)
 */
public class ParentAnswer extends ParentMessage {
    protected UUID actionId;
    protected int error;
    protected String errorMessage;

    public ParentAnswer() {
        this.actionId = UUID.randomUUID();
    }

    public UUID getActionId() {
        return actionId;
    }

    public void setActionId(UUID actionId) {
        this.actionId = actionId;
    }

    public boolean isError() {
        return error != 0;
    }

    public int getError() {
        return error;
    }

    public void setError(int error) {
        this.error = error;
    }

    public String getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(String errorMessage) {
        this.errorMessage = errorMessage;
    }
}
